<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>分享demo</title>
    <meta name="keywords" content="项目关键词" />
    <meta name="description" content="项目描述" />
    <meta name="wap-font-scale" content="no">
    <meta name="viewport" content="width=device-width,height=device-height,initial-scale=1.0,maximum-scale=1.0,user-scalable=no" />
    <link rel="shortcut icon" href="http://www.suning.com/favicon.ico" type="image/x-icon"/>
</head>
<body>

<button id="s">点击分享</button>


<script src='js/zepto.min.js'></script>


<script src='js/SFE.mShare.js'></script>

<script type="text/javascript">

        share.init({
            title:"分享到",   //可选，默认为"分享到"
            maskLayer:true,    //可选，遮罩层，默认为true
            needCancel:true,  //可选，取消按钮，默认为true
            shareTo:{
                wb:{
                    type:"新浪微博",
                    description:"这里是分享出去的内容",
                    url:"http://www.suning.com",
                    imgUrl:"http://image3.suning.cn/uimg/cms/img/143821992646004888.jpg"
                },
                kj:{
                    type:"QQ空间",
                    title:"QQ有可选的分享标题",
                    description:"这里是分享出去的内容",
                    url:"http://www.suning.com",
                    imgUrl:"http://image3.suning.cn/uimg/cms/img/143821992646004888.jpg"
                },
                wm:{
                    type:"生成二维码",
                    url:location.href
                }
            }
        });
        //触发
        window.s.onclick = function(e){
                share.open();       //触发方法
        };

</script>
</body>
</html>
